Defusing the debugging scandal - dedicated debugging technologies for advanced dispatching languages

نویسنده

  • Haihan Yin
چکیده

To increase program modularity, new programming paradigms, such as aspectoriented programming, context-oriented programming, and predicated dispatching, have been researched in recent years. The new-paradigm languages allow changing behavior according to various kinds of contexts at the call sites. A recent statistics shows that at least 66% of skilled engineers world-wide, courses and third party vendors are using languages that support AOP features. Many well-known companies are using these languages in product developments. In our research, we classified these new languages as advanced-dispatching languages. Advanced-dispatching languages are usually implemented as an extension of main-stream languages. After compilation, their programs are transformed to the compiled form of the main-stream language. Due to this compilation mechanism, the information, especially features that are specific to the advanced-dispatching languages, existing in the source code cannot be fully restored during debugging. The information loss increases the effort of comprehending advanced-dispatching programs and fixing advanced-dispatching-specific defects. In this thesis, we performed four works to improve the comprehensibility of debugging information from three debugging techniques — interactive debugging, trace-based debugging, and slicing. We first performed research on the most common debugging technique— interactive debugging. Due to the availability of existing fault models, we proposed a generalized fault model based on four aspect-oriented-specific fault models. The generalized fault model consists of seven fault types and we found a likely pattern for fixing a defect corresponding to each type. Then, we analysed the pattern description and extracted eleven atomic advanced-dispatching-specific debugging tasks. To support the tasks, we modified an existing compiler to keep aspect-oriented information after the compilation, built a dedicated advanced dispatching debugging model, and implemented graphical user interfaces. In addition to the form of debugging information, we analysed the problem where and when the program should be suspended. In interactive debugging, breakpoints are essential to determine the suspending places. For fixing a specific defect, breakpoints are logically related. However, existing debuggers do not support to build logic between breakpoints. Therefore, programmers have to manually perform some repeated tasks. In this thesis, we analysed five common debugging scenarios that require multiple breakpoints. Targeting the investigated scenarios, we designed and implemented a breakpoint language that uses pointcuts to select suspension times in the program. In our language, an expected suspension can be expressively programmed and reached with less or even no irrelevant suspensions. Though the interactive debugging is the most commonly used debugging technique, it becomes handicapped in cases that the observed failure is far away from the defect. Locating the defect is typically a backtracking process through the execution history. However, interactive debugging is performed along with the program execution and cannot restore a past state. Trace-based debugger records events at runtime and supports inspection offline. Existing researches on tracebased debugging for advanced-dispatching languages are limited. We proposed a dedicated trace-based debugger with an user interface that allow programmers to navigate and query the recorded trace. Automation is what software aims for. Slicing is a debugging technique which automatically selects program statements that can influence the failure. It is performed on dependency graphs that contain the inter-relationships between program statements, such as control dependencies, call dependencies. We discussed how three aspect-oriented-specific constructs, which are join point shadows, program compositions, and non-argument context values, can influence the execution of aspect-oriented programs. Considering the three constructs, we developed dependency graphs that are dedicated to aspect-oriented programs, as well as a slicing algorithm that is performed on the developed dependency graphs. We showed that our approach can be applied efficiently for small projects and is able to select all relevant source code. The three debugging techniques analysed in this thesis fully cover phases before, during and after the program execution. For each technique, we have provided a debugging model that explicitly models advanced-dispatching concepts. The generated debugging information is in terms of advanced-dispatching abstractions. Thus, the comprehensibility of debugging advanced-dispatching programs is increased.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Debugging Scandal—The Next Generation

In 1997, the general lack of debugging tools was termed “the debugging scandal” [7]. Today, as new languages are emerging to support software evolution, once more debugging support is lagging. The powerful abstractions offered by new languages are compiled away and transformed into complex synthetic structures. Current debugging tools only allow inspection in terms of this complex synthetic str...

متن کامل

Generic IDE Support for Dispatch-Based Composition

Programming-language research produces a significant number of new programming styles to improve the composability of programs. This increases re-usability as well as other quality characteristics. But although they offer interesting composition concepts, new programming languages are rarely used because IDE support, which developers are used to, is missing. Examples of such IDE support are the...

متن کامل

The Architecture of a Debugger for

Debugging programs written in lazy functional languages is diicult, and there are currently no realistic, general purpose debugging tools available. The basic problem is that computations in general do not take place in the order one might expect. Furthermore, lazy functional languages arèdeclarative'. Hence it is advantageous if debugging takes place at the same, high level of abstraction. Thu...

متن کامل

The Architecture of a Debugger for Lazy Functional Languages

Debugging programs written in lazy functional languages is diicult, and there are currently no realistic, general purpose debugging tools available. The basic problem is that computations in general do not take place in the order one might expect. Furthermore, lazy functional languages arèdeclarative'. Hence it is advantageous if debugging takes place at the same, high level of abstraction. Thu...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2013